Termination w.r.t. Q of the following Term Rewriting System could not be shown:

Q restricted rewrite system:
The TRS R consists of the following rules:

primes -> sieve1(from1(s1(s1(0))))
from1(X) -> cons2(X, from1(s1(X)))
head1(cons2(X, Y)) -> X
tail1(cons2(X, Y)) -> Y
if3(true, X, Y) -> X
if3(false, X, Y) -> Y
filter2(s1(s1(X)), cons2(Y, Z)) -> if3(divides2(s1(s1(X)), Y), filter2(s1(s1(X)), Z), cons2(Y, filter2(X, sieve1(Y))))
sieve1(cons2(X, Y)) -> cons2(X, filter2(X, sieve1(Y)))

Q is empty.


QTRS
  ↳ Non-Overlap Check

Q restricted rewrite system:
The TRS R consists of the following rules:

primes -> sieve1(from1(s1(s1(0))))
from1(X) -> cons2(X, from1(s1(X)))
head1(cons2(X, Y)) -> X
tail1(cons2(X, Y)) -> Y
if3(true, X, Y) -> X
if3(false, X, Y) -> Y
filter2(s1(s1(X)), cons2(Y, Z)) -> if3(divides2(s1(s1(X)), Y), filter2(s1(s1(X)), Z), cons2(Y, filter2(X, sieve1(Y))))
sieve1(cons2(X, Y)) -> cons2(X, filter2(X, sieve1(Y)))

Q is empty.

The TRS is non-overlapping. Hence, we can switch to innermost.

↳ QTRS
  ↳ Non-Overlap Check
QTRS
      ↳ DependencyPairsProof

Q restricted rewrite system:
The TRS R consists of the following rules:

primes -> sieve1(from1(s1(s1(0))))
from1(X) -> cons2(X, from1(s1(X)))
head1(cons2(X, Y)) -> X
tail1(cons2(X, Y)) -> Y
if3(true, X, Y) -> X
if3(false, X, Y) -> Y
filter2(s1(s1(X)), cons2(Y, Z)) -> if3(divides2(s1(s1(X)), Y), filter2(s1(s1(X)), Z), cons2(Y, filter2(X, sieve1(Y))))
sieve1(cons2(X, Y)) -> cons2(X, filter2(X, sieve1(Y)))

The set Q consists of the following terms:

primes
from1(x0)
head1(cons2(x0, x1))
tail1(cons2(x0, x1))
if3(true, x0, x1)
if3(false, x0, x1)
filter2(s1(s1(x0)), cons2(x1, x2))
sieve1(cons2(x0, x1))


Using Dependency Pairs [1,13] we result in the following initial DP problem:
Q DP problem:
The TRS P consists of the following rules:

FILTER2(s1(s1(X)), cons2(Y, Z)) -> SIEVE1(Y)
FILTER2(s1(s1(X)), cons2(Y, Z)) -> FILTER2(X, sieve1(Y))
FILTER2(s1(s1(X)), cons2(Y, Z)) -> FILTER2(s1(s1(X)), Z)
PRIMES -> SIEVE1(from1(s1(s1(0))))
SIEVE1(cons2(X, Y)) -> SIEVE1(Y)
PRIMES -> FROM1(s1(s1(0)))
FILTER2(s1(s1(X)), cons2(Y, Z)) -> IF3(divides2(s1(s1(X)), Y), filter2(s1(s1(X)), Z), cons2(Y, filter2(X, sieve1(Y))))
SIEVE1(cons2(X, Y)) -> FILTER2(X, sieve1(Y))
FROM1(X) -> FROM1(s1(X))

The TRS R consists of the following rules:

primes -> sieve1(from1(s1(s1(0))))
from1(X) -> cons2(X, from1(s1(X)))
head1(cons2(X, Y)) -> X
tail1(cons2(X, Y)) -> Y
if3(true, X, Y) -> X
if3(false, X, Y) -> Y
filter2(s1(s1(X)), cons2(Y, Z)) -> if3(divides2(s1(s1(X)), Y), filter2(s1(s1(X)), Z), cons2(Y, filter2(X, sieve1(Y))))
sieve1(cons2(X, Y)) -> cons2(X, filter2(X, sieve1(Y)))

The set Q consists of the following terms:

primes
from1(x0)
head1(cons2(x0, x1))
tail1(cons2(x0, x1))
if3(true, x0, x1)
if3(false, x0, x1)
filter2(s1(s1(x0)), cons2(x1, x2))
sieve1(cons2(x0, x1))

We have to consider all minimal (P,Q,R)-chains.

↳ QTRS
  ↳ Non-Overlap Check
    ↳ QTRS
      ↳ DependencyPairsProof
QDP
          ↳ DependencyGraphProof

Q DP problem:
The TRS P consists of the following rules:

FILTER2(s1(s1(X)), cons2(Y, Z)) -> SIEVE1(Y)
FILTER2(s1(s1(X)), cons2(Y, Z)) -> FILTER2(X, sieve1(Y))
FILTER2(s1(s1(X)), cons2(Y, Z)) -> FILTER2(s1(s1(X)), Z)
PRIMES -> SIEVE1(from1(s1(s1(0))))
SIEVE1(cons2(X, Y)) -> SIEVE1(Y)
PRIMES -> FROM1(s1(s1(0)))
FILTER2(s1(s1(X)), cons2(Y, Z)) -> IF3(divides2(s1(s1(X)), Y), filter2(s1(s1(X)), Z), cons2(Y, filter2(X, sieve1(Y))))
SIEVE1(cons2(X, Y)) -> FILTER2(X, sieve1(Y))
FROM1(X) -> FROM1(s1(X))

The TRS R consists of the following rules:

primes -> sieve1(from1(s1(s1(0))))
from1(X) -> cons2(X, from1(s1(X)))
head1(cons2(X, Y)) -> X
tail1(cons2(X, Y)) -> Y
if3(true, X, Y) -> X
if3(false, X, Y) -> Y
filter2(s1(s1(X)), cons2(Y, Z)) -> if3(divides2(s1(s1(X)), Y), filter2(s1(s1(X)), Z), cons2(Y, filter2(X, sieve1(Y))))
sieve1(cons2(X, Y)) -> cons2(X, filter2(X, sieve1(Y)))

The set Q consists of the following terms:

primes
from1(x0)
head1(cons2(x0, x1))
tail1(cons2(x0, x1))
if3(true, x0, x1)
if3(false, x0, x1)
filter2(s1(s1(x0)), cons2(x1, x2))
sieve1(cons2(x0, x1))

We have to consider all minimal (P,Q,R)-chains.
The approximation of the Dependency Graph [13,14,18] contains 2 SCCs with 3 less nodes.

↳ QTRS
  ↳ Non-Overlap Check
    ↳ QTRS
      ↳ DependencyPairsProof
        ↳ QDP
          ↳ DependencyGraphProof
            ↳ AND
QDP
                ↳ QDPOrderProof
              ↳ QDP

Q DP problem:
The TRS P consists of the following rules:

FILTER2(s1(s1(X)), cons2(Y, Z)) -> SIEVE1(Y)
FILTER2(s1(s1(X)), cons2(Y, Z)) -> FILTER2(X, sieve1(Y))
FILTER2(s1(s1(X)), cons2(Y, Z)) -> FILTER2(s1(s1(X)), Z)
SIEVE1(cons2(X, Y)) -> SIEVE1(Y)
SIEVE1(cons2(X, Y)) -> FILTER2(X, sieve1(Y))

The TRS R consists of the following rules:

primes -> sieve1(from1(s1(s1(0))))
from1(X) -> cons2(X, from1(s1(X)))
head1(cons2(X, Y)) -> X
tail1(cons2(X, Y)) -> Y
if3(true, X, Y) -> X
if3(false, X, Y) -> Y
filter2(s1(s1(X)), cons2(Y, Z)) -> if3(divides2(s1(s1(X)), Y), filter2(s1(s1(X)), Z), cons2(Y, filter2(X, sieve1(Y))))
sieve1(cons2(X, Y)) -> cons2(X, filter2(X, sieve1(Y)))

The set Q consists of the following terms:

primes
from1(x0)
head1(cons2(x0, x1))
tail1(cons2(x0, x1))
if3(true, x0, x1)
if3(false, x0, x1)
filter2(s1(s1(x0)), cons2(x1, x2))
sieve1(cons2(x0, x1))

We have to consider all minimal (P,Q,R)-chains.
We use the reduction pair processor [13].


The following pairs can be strictly oriented and are deleted.


FILTER2(s1(s1(X)), cons2(Y, Z)) -> SIEVE1(Y)
FILTER2(s1(s1(X)), cons2(Y, Z)) -> FILTER2(X, sieve1(Y))
FILTER2(s1(s1(X)), cons2(Y, Z)) -> FILTER2(s1(s1(X)), Z)
SIEVE1(cons2(X, Y)) -> SIEVE1(Y)
SIEVE1(cons2(X, Y)) -> FILTER2(X, sieve1(Y))
The remaining pairs can at least by weakly be oriented.
none
Used ordering: Combined order from the following AFS and order.
FILTER2(x1, x2)  =  x2
s1(x1)  =  x1
cons2(x1, x2)  =  cons2(x1, x2)
SIEVE1(x1)  =  SIEVE1(x1)
sieve1(x1)  =  sieve1(x1)
filter2(x1, x2)  =  filter
if3(x1, x2, x3)  =  x2
divides2(x1, x2)  =  divides

Lexicographic Path Order [19].
Precedence:
cons2 > [SIEVE1, sieve1, filter, divides]


The following usable rules [14] were oriented:

sieve1(cons2(X, Y)) -> cons2(X, filter2(X, sieve1(Y)))
filter2(s1(s1(X)), cons2(Y, Z)) -> if3(divides2(s1(s1(X)), Y), filter2(s1(s1(X)), Z), cons2(Y, filter2(X, sieve1(Y))))



↳ QTRS
  ↳ Non-Overlap Check
    ↳ QTRS
      ↳ DependencyPairsProof
        ↳ QDP
          ↳ DependencyGraphProof
            ↳ AND
              ↳ QDP
                ↳ QDPOrderProof
QDP
                    ↳ PisEmptyProof
              ↳ QDP

Q DP problem:
P is empty.
The TRS R consists of the following rules:

primes -> sieve1(from1(s1(s1(0))))
from1(X) -> cons2(X, from1(s1(X)))
head1(cons2(X, Y)) -> X
tail1(cons2(X, Y)) -> Y
if3(true, X, Y) -> X
if3(false, X, Y) -> Y
filter2(s1(s1(X)), cons2(Y, Z)) -> if3(divides2(s1(s1(X)), Y), filter2(s1(s1(X)), Z), cons2(Y, filter2(X, sieve1(Y))))
sieve1(cons2(X, Y)) -> cons2(X, filter2(X, sieve1(Y)))

The set Q consists of the following terms:

primes
from1(x0)
head1(cons2(x0, x1))
tail1(cons2(x0, x1))
if3(true, x0, x1)
if3(false, x0, x1)
filter2(s1(s1(x0)), cons2(x1, x2))
sieve1(cons2(x0, x1))

We have to consider all minimal (P,Q,R)-chains.
The TRS P is empty. Hence, there is no (P,Q,R) chain.

↳ QTRS
  ↳ Non-Overlap Check
    ↳ QTRS
      ↳ DependencyPairsProof
        ↳ QDP
          ↳ DependencyGraphProof
            ↳ AND
              ↳ QDP
QDP

Q DP problem:
The TRS P consists of the following rules:

FROM1(X) -> FROM1(s1(X))

The TRS R consists of the following rules:

primes -> sieve1(from1(s1(s1(0))))
from1(X) -> cons2(X, from1(s1(X)))
head1(cons2(X, Y)) -> X
tail1(cons2(X, Y)) -> Y
if3(true, X, Y) -> X
if3(false, X, Y) -> Y
filter2(s1(s1(X)), cons2(Y, Z)) -> if3(divides2(s1(s1(X)), Y), filter2(s1(s1(X)), Z), cons2(Y, filter2(X, sieve1(Y))))
sieve1(cons2(X, Y)) -> cons2(X, filter2(X, sieve1(Y)))

The set Q consists of the following terms:

primes
from1(x0)
head1(cons2(x0, x1))
tail1(cons2(x0, x1))
if3(true, x0, x1)
if3(false, x0, x1)
filter2(s1(s1(x0)), cons2(x1, x2))
sieve1(cons2(x0, x1))

We have to consider all minimal (P,Q,R)-chains.